import request from '@/utils/request'

// 查询后台-小院报销列表
export function listXiaoyuan(query) {
  return request({
    url: '/accounting/xiaoyuan/list',
    method: 'get',
    params: query
  })
}

// 查询后台-小院报销详细
export function getXiaoyuan(id) {
  return request({
    url: '/accounting/xiaoyuan/' + id,
    method: 'get'
  })
}

// 新增后台-小院报销
export function addXiaoyuan(data) {
  return request({
    url: '/accounting/xiaoyuan',
    method: 'post',
    data: data
  })
}

// 修改后台-小院报销
export function updateXiaoyuan(data) {
  return request({
    url: '/accounting/xiaoyuan',
    method: 'put',
    data: data
  })
}

// 删除后台-小院报销
export function delXiaoyuan(id) {
  return request({
    url: '/accounting/xiaoyuan/' + id,
    method: 'delete'
  })
}

// 获取时间信息
export function getTime() {
  return request({
    url: '/accounting/xiaoyuan/getTime',
    method: 'get'
  })
}

// 保存时间信息
export function timeSave(data) {
  return request({
    url: '/accounting/xiaoyuan/timeSave',
    method: 'post',
    data: data
  })
}

// 清除报账日期
export function timeremove() {
  return request({
    url: '/accounting/xiaoyuan/clearTime',
    method: 'get'
  })
}
